// TermVariable.cpp : implementation file
//

#include "stdafx.h"
#include "TermVariable.h"

Token::pointer TermVariable::normalized() const{
	return this->clone();
}
Token::pointer TermVariable::applyArgument(Token::const_reference)  const{
	throw Term::exception("Token::pointer TermVariable::applyArgument(Token::const_reference)  const undefined");
}

TermVariable::TermVariable(const Type& Ty, const string& ss):Term(Ty,ss){}
TermVariable::TermVariable(const TermVariable& Ter):Term(Ter){}
TermVariable::~TermVariable(){}

/**********************
FreeTermVariables
***********************/
FreeTermVariable::FreeTermVariable(const Type& Ty, const string& ss):TermVariable(Ty,ss){}
Token::pointer FreeTermVariable::clone() const{
	return new FreeTermVariable(*this);
}

bool FreeTermVariable::TypeOccursinFreeVariable(Type::const_reference Ty) const{
		return getType().hasSubType(Ty);
	}
/*************************
BoundedTermVariables
*************************/
BoundedTermVariable::BoundedTermVariable(const Type& Ty):TermVariable(Ty){}
Token::pointer BoundedTermVariable::clone() const{
	return new BoundedTermVariable(*this);
}




// TermVariable member functions
